﻿<phone:PhoneApplicationPage 
    x:Class="sodexo.MainPage"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:phone="clr-namespace:Microsoft.Phone.Controls;assembly=Microsoft.Phone"
    xmlns:shell="clr-namespace:Microsoft.Phone.Shell;assembly=Microsoft.Phone"
    xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
    xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
    mc:Ignorable="d" FontFamily="{StaticResource PhoneFontFamilyNormal}"
    FontSize="{StaticResource PhoneFontSizeNormal}"
    Foreground="{StaticResource PhoneForegroundBrush}"
    SupportedOrientations="Portrait" Orientation="Portrait"
    shell:SystemTray.IsVisible="True" Loaded="PhoneApplicationPage_Loaded" xmlns:toolkit="clr-namespace:Microsoft.Phone.Controls;assembly=Microsoft.Phone.Controls.Toolkit" d:DesignHeight="768" d:DesignWidth="480" BorderBrush="{x:Null}" AllowDrop="False">
    <!--<phone:PhoneApplicationPage.Background>
        <ImageBrush ImageSource="/sodexo;component/Images/background.jpg"/>
    </phone:PhoneApplicationPage.Background>-->
  
    <!--LayoutRoot 是包含所有页面内容的根网格-->
    <Grid x:Name="LayoutRoot" >
        <Grid.RowDefinitions>
            <RowDefinition Height="Auto"/>
            <RowDefinition Height="*"/>
        </Grid.RowDefinitions>
        <Grid.Background>
            <ImageBrush ImageSource="/Images/background.jpg"/>
        </Grid.Background>
        <!--TitlePanel 包含应用程序的名称和页标题-->
        <StackPanel x:Name="TitlePanel" Grid.Row="0" Margin="12,17,0,28">
            <TextBlock x:Name="ApplicationTitle" Text="索迪斯联盟商户信息" Style="{StaticResource PhoneTextNormalStyle}"/>
            <TextBlock x:Name="PageTitle" Text="查询" Margin="9,-7,0,0" Style="{StaticResource PhoneTextTitle1Style}" FontSize="64" />
        </StackPanel>

        <!--ContentPanel - 在此处放置其他内容-->
        <Grid x:Name="ContentPanel" Grid.Row="1" Margin="4,0,4,0">
            <ScrollViewer HorizontalAlignment="Stretch" Margin="0,-12,0,0" Name="scrollViewerCardType" VerticalAlignment="Stretch">
                <StackPanel>
                    <StackPanel  Name="StackPanelCardType">
                        <StackPanel.Resources>
                            <Style 
                                TargetType="HyperlinkButton" 
                                BasedOn="{StaticResource PhoneButtonBase}"/>
                        </StackPanel.Resources>
                    </StackPanel>
                    <Rectangle Height="40"/>
                    <toolkit:ListPicker  Name="listPickerCardType"  Header="适用卡" SelectionChanged="listPickerCardType_SelectionChanged" Background="White">
                        <toolkit:ListPicker.ItemTemplate>
                            <DataTemplate>
                                <StackPanel>
                                    <TextBlock Text="{Binding Text}" TextWrapping="Wrap"/>
                                </StackPanel>
                            </DataTemplate>
                        </toolkit:ListPicker.ItemTemplate>
                    </toolkit:ListPicker>
                    <toolkit:ListPicker  Name="listPickerDistrict"  Header="地区" SelectionChanged="listPickerDistrict_SelectionChanged" ItemsSource="{Binding}" Background="White">
                        <toolkit:ListPicker.ItemTemplate>
                            <DataTemplate>
                                <StackPanel>
                                    <TextBlock Text="{Binding Text}" TextWrapping="Wrap"/>
                                 
                                </StackPanel>
                            </DataTemplate>
                        </toolkit:ListPicker.ItemTemplate>
                        <toolkit:ListPicker.FullModeItemTemplate>
                            <DataTemplate >
                                <StackPanel Orientation="Horizontal" Margin="0 21 0 20">
                                    <TextBlock Text="{Binding Text}" TextWrapping="Wrap"/>
                                    
                                    <!--<toolkit:LongListSelector>
                                        <toolkit:LongListSelector.GroupItemsPanel>
                                            <ItemsPanelTemplate>
                                                <toolkit:WrapPanel Orientation="Horizontal"/>
                                            </ItemsPanelTemplate>
                                        </toolkit:LongListSelector.GroupItemsPanel>
                                    </toolkit:LongListSelector>-->
                                </StackPanel>
                            </DataTemplate>
                        </toolkit:ListPicker.FullModeItemTemplate>
                    </toolkit:ListPicker>
                    <toolkit:PerformanceProgressBar Name="performanceProgressBarUpdate" Height="8" IsIndeterminate="True" />
                </StackPanel>
                
            </ScrollViewer>
        </Grid>
    </Grid>
 
    <!--演示 ApplicationBar 用法的示例代码-->
    <phone:PhoneApplicationPage.ApplicationBar>
        <shell:ApplicationBar IsVisible="True" IsMenuEnabled="True"  BackgroundColor="#FF4B89D1" Opacity="0.25">
            <shell:ApplicationBarIconButton IconUri="/Images/appbar.feature.search.rest.png" Text="搜索" Click="ApplicationBarIconButton_Click" IsEnabled="False" x:Name="AppBarSearchIcon" />
            <shell:ApplicationBar.MenuItems>
                <shell:ApplicationBarMenuItem Text="搜索 " Click="ApplicationBarMenuItem_Click" IsEnabled="False" x:Name="AppBarSearchMenu" />
                <shell:ApplicationBarMenuItem Text="帮助 "  x:Name="AppBarAboutMenu" Click="ApplicationBarMenuItem_About" />
            </shell:ApplicationBar.MenuItems>
        </shell:ApplicationBar>
    </phone:PhoneApplicationPage.ApplicationBar>

</phone:PhoneApplicationPage>